package edu.xlh.travel.service;

import com.alibaba.fastjson.JSONArray;
import edu.xlh.travel.common.Result;
import edu.xlh.travel.pojo.Scenic;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestParam;

import javax.servlet.http.HttpSession;
import java.io.IOException;
import java.util.HashMap;

public interface ScenicService {
    String findAllScenic(Model mode , Integer start, Integer limit, Integer price, Integer star);

    String findById(Model model , String id);

    String findAll(Model model, Integer start,
                         Integer limit,
                         String search_key);
    Result findAll(int page  , int size , HttpSession session);

    Result edit(String id, Scenic scenic , HttpSession session);

    Scenic findByScenicId(String scenicId);

    Result editMiaoShuOrComment(String id, Scenic scenic , HttpSession session);

    Result deleteById(String id, HashMap hashMap, HttpSession session);

    Result addScenic(Scenic scenic, HttpSession session);

    Result batchDelete(JSONArray jsonArray, HttpSession session);

    Result QueryScenicByCondition(Integer page, Integer limit, Scenic scenic, HttpSession session) throws IOException;
}
